package ru.ifmo.contest.games;

import java.awt.*;
import java.io.File;
import java.io.FileNotFoundException;
import java.io.PrintWriter;
import java.util.ArrayList;
import java.util.List;

/**
 * @author avhaliullin
 */
public class Gen {
    public static void main(String[] args) throws FileNotFoundException {
        PrintWriter out = new PrintWriter(new File("gameofthrones.in"));
        int n = 49;
        out.println(n);
        List<Dimension> list = new ArrayList<Dimension>();
        for (int i = 0; i < n; i++) {
            for (int j = 0; j < n; j++) {
                if (!(i % 2 == 0 && j % 2 == 0)) {
                    list.add(new Dimension(i, j));
                }
            }
        }
        out.println(list.size());
        out.println(String.format("1 1 %1$d %2$d", n, n));
        for (Dimension d : list) {
            out.println((d.width + 1) + " " + (d.height + 1));
        }
        out.close();
    }
}
